package com.xqboss.apps.dto.user;

import com.xqboss.apps.enums.user.PayTypeEnum;
import com.xqboss.apps.enums.user.WithdrawWayEnum;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Positive;
import java.math.BigDecimal;

/**
 * <p>
 *     用户申请提现请求体
 * </p>
 * @author Trent
 * @date 2023/8/19
 */
@Data
public class ApplyWithdrawDto {

    @ApiModelProperty(value = "提现方式: ", required = true)
    @NotNull(message = "请选择提现方式")
    private WithdrawWayEnum withdrawWay;

    @ApiModelProperty(value = "提现账号", required = true)
    @NotEmpty(message = "请输入提现账号")
    @Length(min = 3, max = 30, message = "提现账号异常")
    private String bankAccount;

    @ApiModelProperty(value = "提现金额", required = true)
    @NotNull(message = "请输入提现金额")
    @Positive(message = "提现金额错误")
    private BigDecimal amount;

    @ApiModelProperty(value = "支付密码", required = true)
    @NotEmpty(message = "请输入支付密码")
    @Length(min = 6, max = 6, message = "支付密码错误")
    private String payPwd;

    @ApiModelProperty("提现银行名称")
    private String bankName;

    @ApiModelProperty("提现银行卡姓名")
    private String bankUser;

    @ApiModelProperty("银行支行信息")
    private String bankBranch;
}
